<?php 
@session_start();

class AdminPanel {
	public static function RunPanel() {
		include_once('admin_view.php');
		AdminView::DisplayHeader();
		switch($_SESSION['page']) {
			case 'index':
				AdminView::DisplayIndexContent();
				break;
			case 'hardware':
				AdminView::DisplayHardwareContent();
				break;
			case 'users':
				AdminView::DisplayUsersContent();
				break;
			case 'user_edit':
				AdminView::DisplayUserEditContent();
				break;
			case 'users_exp':
				AdminView::DisplayUsersExpContent();
				break;
			case 'hardware_edit':
				AdminView::DisplayHardwareEditContent();
				break;
		}
		AdminView::DisplaySidebar();
		AdminView::DisplayFooter();
	}
	
	public static function RunPanelNoRights() {
		include_once('admin_view.php');
		AdminView::DisplayHeaderNoRights();
		AdminView::DisplayContentNoRights();
		AdminView::DisplaySidebarNoRights();
		AdminView::DisplayFooter();
	}
}
?>